#include <stdio.h>

int main()
{
	double cm,foot1;
	int foot,inch;
	
	scanf("%lf", &cm);
	
	
	foot1 = cm/100/0.3048;
	foot = foot1/1;
	inch = (foot1 - foot)*12;
	printf("%d %d", foot, inch);
}
